District heating (DH) benefits from economy of scale with mass production of heat from central heating plants. It is an energy efficient and environmentally benign solution when compared with decentralized heat generation. In many countries, district heating has been actively promoted as an important component in the national strategic energy planning [1].
A DH system includes heat generation, distribution and utilization. The heat generated in a heating plant is delivered through the DH network to the end users. Due to the high investment and the long payback period, successful implementation of a DH system requires deliberated design, good maintenance and economical operation.
Optimal planning of the DH system has been arousing great interest in recent decades. Numerous optimization works have been carried out which focused on different aspects including the DH plant configuration optimization [2], the optimal dispatch in a DH plant [3], the search for an optimal mix of renewable and non-renewable based energy supply in the DHC (district heating and/or district cooling) network [4] and in the urban energy supply infrastructure [5], as well as the search for the desirable mix of building types with diverse daily heating/cooling load patterns [6], etc. Furthermore, the optimal planning of DH in the future renewable-based energy system has been investigated through the integrated energy planning approach to evaluate the entire energy system including heating and electricity generation as well as end user energy consumption and energy savings [7].
In a DH system, the DH pipeline cost accounts for a significant part of the whole system investment. The optimal routing of the DH pipeline and the optimal pipe diameter based on the design and operation conditions are essential to achieve economic savings and energetic/exergetic consumption reduction. Kalinci et al. determined the optimal DH pipe diameter for a geothermal plant by solving the derivative of the formulated objective function [8]. Li et al. applied the genetic algorithm to find the optimal DHC network pipe diameter for a seawater-source heat pump plant [9]. The optimal DH network configuration has been studied by several researchers. Chan et al. [10] studied the approach to find the optimal routing in a DC system using the genetic algorithm. Dobersek and Goricanec [11] performed optimization work with non-linear programming based on Simplex method to find the optimal routing and pipe diameter in a tree-structured DH network. Soderman [12] formulated a mixed integer linear programming problem to find the optimal production and storage unit locations and the DH pipeline connection.
In this paper, the configuration of a DH network is optimized based on a low temperature DH (LTDH) system with a network supply/return temperature at 55 oC / 25 oC. The LTDH concept carried out in Denmark utilizes a network supply temperature close to the end user required temperature at around 50 oC [13]. The reduced network supply temperature has the advantages to reduce the network heat loss, increase CHP plant power generation capability, and utilize waste and renewable heat in various spectrums. In the analysis, the influence on the optimal network configuration due to the hydraulic and thermal constraints is emphasized through detailed network hydraulic and thermal modelling.
In the existing literature, the DH network design and configuration optimization works have mainly formulated the objective function as the summation of pipeline investment and the pumping cost. The heat loss along the DH network, however, was often neglected in the network routing and pipeline diameter optimization process. Depending on the DH network supply/return temperature, the pipeline diameter and length, the network heat loss may account for a significant part of the total network input energy, and thus plays the role in determining the optimal network configuration. This can be illustrated in the following example.
As shown in Figure 1, there are two possible connection routes between consumers B, C to the heating plant A: route AB-BC and route AC-CB. The following assumptions are made regarding the heating demand and the network geometry:
Example for pipe heat loss influencing on the network configuration

Though the total length for route AB-BC is longer than that of AC-CB, due to the larger diameter, thus higher heat loss in section CB than that in the section BC, the incurred operational cost is higher in route AC-CB, which may exceed the economical saving due to the shorter pipe length.
Furthermore, the DH network is designed based on the design winter condition. During the season with low heating demand as in the summer when the heating load only comes from the domestic hot water demand, the temperature drop due to the reduced network flow rate makes the supply temperature at the consumer end lower than the required value. In this case, extra flow is required from the plant to compensate the temperature drop through the thermal by-pass system. The by-pass flow will increase the return water temperature thus further increase the network heat loss [14], [15]. This situation becomes worse for the larger pipe diameter than the smaller pipe diameter. Therefore, the network heat loss and the heat loss due to network thermal by-pass should be counted in the identification of the DH network optimal configuration.
The DH network is designed with one heating plant and 10 end users. Each end user in the network represents a building block. The topology of the heating plant and the end users are shown in Figure 2 where the circle represents the heating plant and the squares represent the end users.
Topology of the heating plant and end users

The DH network is designed with twin pipes with the supply and return pipes placed in the same casing. Based on the market available products [16], two different types of twin pipes are considered in the simulation: AluFlex multilayer flexible pipe and straight steel pipe. The AluFlex is a multi-layer ‘sandwiched’ type pipe containing aluminium and PEX (cross-linked polyethylene) which has the advantages both of flexibility and durability. The DH pipes are selected from continuous dimension ranging from Alx14 to 32 for AluFlex pipe and DN 32 to DN80 for straight steel pipes. Table 1 shows the pipe inner diameter, roughness and the unit price. The heat transfer coefficients under different ambient temperatures are calculated with the analytical solution developed from the multi-pole method [17].
Available commercial district heating pipes
Type | Inner Diameter, mm | Roughness Factor, mm | Price, $/m | |
---|---|---|---|---|
AluFlex | Alx 14/14 | 10 | 0.02 | 233 |
Alx 16/16 | 11.6 | 0.02 | 233 | |
Alx 20/20 | 15 | 0.02 | 238 | |
Alx 26/26 | 20 | 0.02 | 298 | |
Alx 32/32 | 26 | 0.02 | 303 | |
Steel | Tws-DN32 | 37.2 | 0.1 | 345 |
Tws-DN40 | 43.1 | 0.1 | 354 | |
Tws-DN50 | 54.5 | 0.1 | 385 | |
Tws-DN65 | 70.3 | 0.1 | 397 |
In order to reduce the pipe geometry, the pipeline is designed with network supply temperature at 70 oC instead of 55 oC, by assuming that the plant is able to temporarily supply the network at higher temperature during the design peak heating load condition.
The design heating load for each building block is shown in Table 2. The annual heating load is divided into 8 periods. The load factors are assigned to each period, as shown in Table 3.
Building design heating load
Building Nodes | Design Load, kW |
---|---|
1 | 35 |
2 | 45 |
3 | 45 |
4 | 55 |
5 | 100 |
6 | 60 |
7 | 70 |
8 | 60 |
9 | 80 |
10 | 50 |
Building heating load factors
Periods | Load factor |
---|---|
1 | 0.62 |
2 | 0.49 |
3 | 0.41 |
4 | 0.34 |
5 | 0.26 |
6 | 0.17 |
7 | 0.11 |
8 | 0.07 |
The aim of the network configuration optimization is to find the optimal network pipeline connections and optimal pipe diameters so that the total investment and operational cost can be minimized. The net present cost (NPC) value is formulated as the objective function. The technical lifetime and the depreciation time are 30 years for the DH pipe and 20 years for the main pump. The interest rate is set as 6%.
The annual operational cost includes the cost due to network heat loss, the pumping power cost, the maintenance cost and the emission cost.
The unit prices for the heating and electricity are $59/MWh and $108/MWh, respectively, according to the average value between 2010 and 2030 in Danish conditions [18]. Similarly, the CO2 emission cost is $37/ton with the emission factors 177 kg/MWh for DH and 862 kg/MWh for electricity at the end user [18]. The DH maintenance cost is taken as $2.3 per MWh heating energy production [19].
The annual operational cost is converted to the NPC through the discount factor:
According to the design flow rate, the Grundfoss CRI 15-9 is selected. Two pumps will be used during the DH system lifetime with $4,025 per pump [20]. The pipeline cost is shown in Table 1. The NPC is the summation of total investment cost and the total annual operational cost expressed as the present value. In order to calculate the pipe investment, the connectivity between two different nodes in the network is represented by the binary decision variable xi,j.
The objective function is subjected to the constraints of network hydraulic and thermal conditions, the network maximum allowable pressure and temperature drop, the pipeline maximum allowable velocity and the available commercial pipeline diameters.
Equations 9-11 show the mass continuity and hydraulic balance in the network. A is the incident matrix determined by the network topology. As the studied network has a tree-shaped structure, A is a square matrix(n − 1) × (n − 1). M is the column vector for pipeline flow rate. Q is the column vector for the flow rate at each node. Ph is the vector to describe the pump head. S is a diagonal matrix with an order (n-1) which represents the friction coefficient for each pipeline.
No isolated loop is allowed in the network and the number of pipes equals n-1. Eq. 14 is formulated to prevent the isolated loop so that each node connects at least once with other nodes. According to the constraint in Eq. 15, the flow direction is enforced as positive according to the encoding scheme presented in Table 4. The network is designed with 10 bar limit and the plant holding pressure is set as 2 bar. The pressure drop at each end user is assumed as 2 bar. The maximum allowable network velocity is set as 2 m/s which gives the constraint in Eq. 17. The velocity in each pipe section is initially set as 1 m/s and is adjusted to maximally exploit the allowable network pressure drop at each separate route.
DH network configuration encoding
Pipe Section | Pipe No | Up Node | Down Node | U_Limit m/s | Pipe Section | Pipe No | Up Node | Down Node | U_Limit m/s |
---|---|---|---|---|---|---|---|---|---|
11-10 | 1 | 11 | 10 | 1 | 8-3 | 35 | 8 | 3 | 1 |
11-9 | 2 | 11 | 9 | 1 | 8-2 | 36 | 8 | 2 | 1 |
11-8 | 3 | 11 | 8 | 1 | 8-1 | 37 | 8 | 1 | 1 |
11-7 | 4 | 11 | 7 | 1 | 7-10 | 38 | 7 | 10 | 1 |
11-6 | 5 | 11 | 6 | 1 | 7-9 | 39 | 7 | 9 | 1 |
11-5 | 6 | 11 | 5 | 1 | 7-8 | 40 | 7 | 8 | 1 |
11-4 | 7 | 11 | 4 | 1 | 7-6 | 41 | 7 | 6 | 1 |
11-3 | 8 | 11 | 3 | 1 | 7-5 | 42 | 7 | 5 | 1 |
11-2 | 9 | 11 | 2 | 1 | 7-4 | 43 | 7 | 4 | 1 |
11-1 | 10 | 11 | 1 | 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| 4 | 8 | 1 |
8-4 | 34 | 8 | 4 | 1 | 4-7 | 68 | 4 | 7 | 1 |
4-6 | 69 | 4 | 6 | 1 | 2-8 | 85 | 2 | 8 | 1 |
4-5 | 70 | 4 | 5 | 1 | 2-7 | 86 | 2 | 7 | 1 |
4-3 | 71 | 4 | 3 | 1 | 2-6 | 87 | 2 | 6 | 1 |
4-2 | 72 | 4 | 2 | 1 | 2-5 | 88 | 2 | 5 | 1 |
4-1 | 73 | 4 | 1 | 1 | 2-4 | 89 | 2 | 4 | 1 |
3-10 | 74 | 3 | 10 | 1 | 2-3 | 90 | 2 | 3 | 1 |
3-9 | 75 | 3 | 9 | 1 | 2-1 | 91 | 2 | 1 | 1 |
3-8 | 76 | 3 | 8 | 1 | 1-10 | 92 | 1 | 10 | 1 |
3-7 | 77 | 3 | 7 | 1 | 1-9 | 93 | 1 | 9 | 1 |
3-6 | 78 | 3 | 6 | 1 | 1-8 | 94 | 1 | 8 | 1 |
3-5 | 79 | 3 | 5 | 1 | 1-7 | 95 | 1 | 7 | 1 |
3-4 | 80 | 3 | 4 | 1 | 1-6 | 96 | 1 | 6 | 1 |
3-2 | 81 | 3 | 2 | 1 | 1-5 | 97 | 1 | 5 | 1 |
3-1 | 82 | 3 | 1 | 1 | 1-4 | 98 | 1 | 4 | 1 |
2-10 | 83 | 2 | 10 | 1 | 1-3 | 99 | 1 | 3 | 1 |
2-9 | 84 | 2 | 9 | 1 | 1-2 | 100 | 1 | 2 | 1 |
The network supply temperature at each end user is ensured through the inequality, Eq. 18. An iterative approach is adopted to gradually increase the network mass flow rate until the supply temperature at the end user exceeds the set point by-pass temperature. The DH pipeline is selected from the market-available commercial products. The product which has the diameter that is larger and closest to the calculated pipe diameter is selected as the design pipe diameter.
The network supply temperature at each end user is ensured through the inequality, equation 18. An iterative approach is adopted to gradually increase the network mass flow rate until the supply temperature at the end user exceeds the set point by-pass temperature. The DH pipeline is selected from the market-available commercial products. The product which has the diameter that is larger and closest to the calculated pipe diameter is selected as the design pipe diameter.
Figure 3. Flow chart for district heating network configuration optimization shows the flow chart for the DH network configuration optimization. The connection between the heat generation plant and the end users can be represented with mixed integer and the node head and temperature are formed as non-linear. In order to find the optimal DH network pipeline configuration, optimization algorithm that handles the mixed integer nonlinear programming problem is chosen.
Flow chart for district heating network configuration optimization

The Genetic Algorithm (GA) is applied to find the minimum NPC based on the design and operational conditions. The GA is inspired by Darwin’s theory to mimic the process of natural evolution. It is a stochastic search algorithm to find the optimal or near optimal value through successive selection, mutation and reproduction. It has been widely applied in recent years for energy system optimization [9], [10], [21].
The pipe network configuration is encoded as a vector of integers. The length of the vector equals the number of pipes which is n-1. Each integer in the vector represents a uni-directional connection between two different nodes. The integer is numbered in a sequential way from 1 to maximum (n-1)2.
Figure 4 shows the optimal position of the heating plant and its connections with each consumer node. The plant position moves from the initial location (0, 0) to the location (3, 3). Table 5 shows the information of the network. The pipe types range from Alx 20 to Tws-DN40 with a total length of 1927 m. The maximum network velocity is 1.38 m/s in the pipe section 9.
Optimal district heating network configuration

Information on network configuration
Pipe No | Type | Diameter, mm | Length, m | Velocity, m/s | Up Node | Down Node |
---|---|---|---|---|---|---|
2 | Alx 26/26 | 20 | 291.5476 | 1.382 | Plant | 9 |
31 | Tws-DN32 | 37.2 | 200 | 0.8989 | 8 | 7 |
38 | Alx 26/26 | 20 | 223.6068 | 0.8634 | 7 | 10 |
6 | Alx 32/32 | 26 | 158.1139 | 1.3804 | Plant | 5 |
7 | Alx 32/32 | 26 | 158.1139 | 1.0224 | Plant | 4 |
71 | Alx 20/20 | 15 | 141.4214 | 1.3817 | 4 | 3 |
9 | Alx 20/20 | 15 | 254.951 | 1.3819 | Plant | 2 |
3 | Tws-DN32 | 37.2 | 158.1139 | 1.1988 | Plant | 8 |
41 | Alx 26/26 | 20 | 141.4214 | 1.0363 | 7 | 6 |
64 | Alx 20/20 | 15 | 200 | 1.0745 | 5 | 1 |
The optimized DH network includes 6 separate routes. Figure 5 shows the pressure head distribution at each consumer node along different routes. A small velocity limit is pre-assumed for each pipe as the initial guess value to calculate the pressure distribution at each node. The allowable network pressure drop is exploited by continuously increasing the velocity limit in the pipelines until the pressure drop from the plant to the critical user (who has the lowest supply pressure head at the network) exceeds the allowable network pressure drop. The minimum pressure head occurs at node 1 which is the critical user in the optimized DH network.
Pressure distribution along each route

The temperature along the network drops due to the pipeline heat loss to the ground. When there has no thermal bypass at the end user, excessive temperature drop may occur during low heating load seasons and makes the supply temperature at the consumer node lower than the minimum required value. In the study, a set-point temperature of 52 oC is assumed.
As shown in Fig. 6 (top left), without thermal by-pass, the supply temperature at some consumer node drops below 47 oC in the low heating load seasons. By using the by-pass, the minimum node supply temperature is raised to higher than 52 oC (Fig. 6: top right). However, as the by-pass water does not go through the consumer heating units, but instead flows back to the return line and mixes with the return water directly, it will increase the return water temperature. Fig. 6 (bottom left) shows the return water temperature at each consumer node. When the by-pass is used, the return water temperature at some consumer node reaches as high as 45 oC. This increases the heat loss along the return pipe.
Temperature variation at different consumer nodes.
Top left: Supply water temperature without by-pass
Top right: Supply water temperature with by-pass
Bottom left: Return water temperature with by-pass

In this study, the network heat loss due to increased network return temperature does not change the network configuration. However, it is worth knowing that the DH utility prefers large network temperature difference and sometimes imposes fines on consumers who have high network return temperature. Considering such extra cost into the objective function, it might be possible to change the network connection to a configuration which results in lower network return temperature or less use of the thermal by-pass.
The genetic algorithm is applied to find a DH network optimal configuration based on the design and operational conditions. The possible routes between two nodes are represented as integers and the existence of the connection is determined through a binary decision variable. The algorithm optimizes both the pipe connections and the position of the heating plant. The NPC is formulated as the objective function to be minimized, subjected to the network hydraulic and thermal constraints.
The effect of thermal by-pass is analysed. Thermal by-pass increases the return water temperature and thus causes extra network heat loss. In the analysis, this extra heat loss does not influence the optimal DH pipe connections. However, additional cost due to fines on excessive high network return temperature may change the optimal network configuration.
C - cost, $
d - inner pipe diameter, mm
f - friction coefficient, -
L - length, m
M - mass flow, kg/s
N - node number, -
P - pressure, kPa
Q - heating demand, kW
T - temperature, oC
U - thermal transmittance, W/m2K
V - velocity, m/s
ρ - density, kg/m3
ε - internal roughness of pipe, mm
μ - dynamic viscosity, N s/m2
Χ - binary decision variable, -
d - downstream
g - ground
i - node
j - pipe
u - upstream
DF - discount factor
DH - district heating
GA - genetic algorithm
NPC - net present cost in $
The Role of District Heating in Future Renewable Energy Systems ,Energy , Vol. Vol. 35 , :1381-13902010, https://doi.org/10.1016/j.energy.2009.11.023
, Multi-Criteria Optimization of A District Cogeneration Plant integrating A Solid Oxide Fuel Cell-Gas Turbine Combined Cycle, Heat Pumps and Chillers ,Energy , Vol. Vol. 28 , :497-5182003, https://doi.org/10.1016/S0360-5442(02)00161-5
, Operation Planning of District Heating and Cooling Plants Using Genetic Algorithms for Mixed Integer Programming ,ApplSoft Comput , Vol. Vol .1 , :139-1502001
, Optimization of Structure and Operation of District Cooling Networks in Urban Regions ,ApplTherm Eng , Vol. Vol. 27 , :2665-26762007, https://doi.org/10.1016/j.applthermaleng.200705.004
, Optimization Based Design of A District Energy System for AN Eco-Town in the United Kingdom ,Energy , Vol. Vol. 36 , :1292-13082011, https://doi.org/10.1016/j.energy.2010.11.014
, Building-Mix Optimization in District-Cooling System Implementation ,ApplEnerg , Vol. Vol. 77 , :1-132004
, End-use Energy Savings and District Heating Expansion in ALocal Renewable Energy System – A Short-Term Perspective ,ApplEnerg , Vol. Vol.92 , :831-8422012, https://doi.org/10.1016/j.apenergy.2011.08.040
, Determination of Optimum Pipe Diameter Along with Energetic and Exergetic Evaluation of Geothermal District Heating System: Modelling and Application ,Energ Buildings , Vol. Vol. 40 , :742-7552008, https://doi.org/10.1016/j.enbuild.2007.05.009
, Optimal Design of District Heating and Cooling Pipe Network of Seawater-Source Heat Pump ,Energ. Buildings , Vol. Vol. 42 , :100-1042010, https://doi.org/10.1016/j.enbuild.2009.07.016
, Optimization of Distribution Piping Network in District Cooling System Using Genetic Algorithm with Local Search ,Energ Convers and Manage , Vol. Vol. 48 , :2622-26292007, https://doi.org/10.1016/j.enconman.200705.008
, Optimization of Tree Path Pipe Network with Nonlinear Optimization Method ,ApplTherm Eng , Vol. Vol. 29 , :1584-15912009, https://doi.org/10.1016/j.applthermaleng.2008.07.017
, Structural and Operational Optimisation of Distributed Energy Systems ,ApplTherm Eng , Vol. Vol. 26 , :1400-14082006, https://doi.org/10.1016/j.applthermaleng.2005.05.034
, A New Low-Temperature District Heating System for Low-Energy Buildings ,The 11th International Symposium on District Heating and Cooling , 2008
, Design of a low temperature district heating network with supply recirculation ,12th International Symposium on District Heating and Cooling , 2010
, Energy and Exergy Analysis of Low Temperature District Heating Network ,Energy , Vol. Vol. 45 , :237-2462012, https://doi.org/10.1016/j.energy.201203.056
, - ,
, Steady-state heat loss from insulated pipes ,Ph.D. Thesis , 1991
, - ,
Forudsætninger for Samfundsøkonomiske Analyser På Energiområdet (Prerequisites for Macroeconomic Analysis On Energy) , Profitability of Low Energy District Heating for Areas with Low Energy Buildings ,M. Sc. Thesis , 2010
, - ,
Grundfos Industrial Products Price List , 2010 Thermal-Economic Optimization of A Distributed Multi-Generation Energy System—A Case Study of Beijing ,ApplTherm Eng , Vol. Vol 26 , :709-7192006, https://doi.org/10.1016/j.applthermaleng.2005.09.005
,